package com.ruoyi.cms.domain;

import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 政策资讯对象 cms_content
 * 
 * @author hct
 * @date 2022-01-22
 */
@Data
public class CmsContent extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 编号 */
    private Long id;

    /** 内容 */
    @Excel(name = "内容")
    private String content;


    /** 头图 */
    @Excel(name = "头图")
    private String img;


    /** 标题 */
    @Excel(name = "标题")
    private String title;

    /** 栏目id */
    @Excel(name = "栏目id")
    private Long typeId;

    private CmsType cmsType;
    /** 是否热点 */
    @Excel(name = "是否热点")
    private Long hot;

    /** 是否上架 */
    @Excel(name = "是否上架")
    private Integer isMarketable;

    private String author;
    /**
     * 排序
     */
    private Integer sort;

    /** 上架时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "上架时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date marketableTime;

    public void setId(Long id) 
    {
        this.id = id;
    }

    public Long getId() 
    {
        return id;
    }
    public void setContent(String content) 
    {
        this.content = content;
    }

    public String getContent() 
    {
        return content;
    }
     public void setImg(String img)
    {
        this.img = img;
    }

    public String getImg() 
    {
        return img;
    }

    public String getTitle() 
    {
        return title;
    }
    public void setTypeId(Long typeId)
    {
        this.typeId = typeId;
    }

    public Long getTypeId() 
    {
        return typeId;
    }
    public void setHot(Long hot) 
    {
        this.hot = hot;
    }

    public Long getHot() 
    {
        return hot;
    }
    public void setIsMarketable(Integer isMarketable)
    {
        this.isMarketable = isMarketable;
    }

    public Integer getIsMarketable()
    {
        return isMarketable;
    }
    public void setMarketableTime(Date marketableTime)
    {
        this.marketableTime = marketableTime;
    }

    public Date getMarketableTime()
    {
        return marketableTime;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("content", getContent())
            .append("img", getImg())
            .append("createTime", getCreateTime())
            .append("updateTime", getUpdateTime())
            .append("title", getTitle())
            .append("createBy", getCreateBy())
            .append("typeId", getTypeId())
            .append("updateBy", getUpdateBy())
            .append("hot", getHot())
            .append("isMarketable", getIsMarketable())
            .append("marketableTime", getMarketableTime())
             .toString();
    }
}
